<?php

namespace common\models\patient;

use Yii;

/**
 * This is the model class for table "{{%patient_consume}}".
 *
 * @property int $id
 * @property int $patient_id 患者ID
 * @property int $total_money 收费金额【单位：分】
 * @property int $discount_rate 折扣【单位：%】
 * @property string $doctor_name 医生名
 * @property int $pay_time 消费时间
 * @property int $created_at 创建时间
 * @property int $updated_at 更新时间
 */
class PatientConsume extends \common\models\base\BaseModel
{
    /**
     * {@inheritdoc}
     */
    public static function tableName()
    {
        return '{{%patient_consume}}';
    }

    /**
     * {@inheritdoc}
     */
    public function rules()
    {
        return [
            [['patient_id', 'total_money', 'discount_rate', 'pay_time', 'created_at', 'updated_at'], 'integer'],
            [['doctor_name'], 'string', 'max' => 32],
        ];
    }

    /**
     * {@inheritdoc}
     */
    public function attributeLabels()
    {
        return [
            'id' => 'ID',
            'patient_id' => '患者ID',
            'total_money' => '收费金额【单位：分】',
            'discount_rate' => '折扣【单位：%】',
            'doctor_name' => '医生名',
            'pay_time' => '消费时间',
            'created_at' => '创建时间',
            'updated_at' => '更新时间',
        ];
    }
}
